/**
* Copyright (c) By zengqh.
*
* This program is just for fun or demo, in the hope that it  
* will be useful, you can redistribute it and/or modify freely.
*
* Time: 2012/08/30
* File: AnimationSceneNode.cpp
* Blog: http://www.cnblogs.com/zengqh/
**/

/* very simple anim !!! */

#include "AnimationSceneNode.h"

AnimationSceneNode::AnimationSceneNode(
SceneNode* parent, 
SceneManager* scene_mgr, 
s32 id /* = -1 */, 
s32 type /* = 0 */, 
const glm::vec3& position,
const glm::vec3& rotation,
const glm::vec3& scale)
: SceneNode(parent, scene_mgr, id, type, position, rotation, scale)
, _is_anim_start(false)
, _need_update_first_time(true)
{
	
}

AnimationSceneNode::~AnimationSceneNode()
{
	safe_delete(_anim);
}

void AnimationSceneNode::setAnimation(AnimationTrack* track)
{
	_anim = track;
}

void AnimationSceneNode::render()
{
	
}

void AnimationSceneNode::onAnimation(f32 time)
{
	
}

void AnimationSceneNode::startAnim()
{
	_is_anim_start = true;
}

void AnimationSceneNode::stopAnim()
{
	_is_anim_start = false;
}